1. Field of the Invention
The present invention relates to a storage control device wherein the write-back method is adopted, and in particular to method of selecting data in the cache memory which is to be written to the storage.
2. Description of the Related
The performance of a storage control device is determined by the response time to data read and data write requests from the host computer. Generally speaking, the data transfer rate with the higher-level device (host) connected to the storage control device is higher than the data transfer rate with the storage which is also connected to it. The storage control device is equipped with a cache memory in order to improve its performance. In this case, it is possible for the data transfer rate between the cache memory and the high-level device to attain a value which is close to the theoretical threshold value of the transfer rate between the storage control device and the higher-level device.
There are two methods of using the cache memory, namely write-through and write-back. The write-through system permits use of the cache memory alone only for read requests from the higher-level device. In the case of write requests, both the cache memory and the storage are involved simultaneously. The write-back system, on the other hand, permits use of the cache memory alone for both read and write requests from the higher-level device. In the write-back system, the higher-level device is notified when write data from the high-level device to the storage has been written to the cache memory. This data is then written from the cache memory to the storage (write-back) asynchronously with the writing of data from the higher-level device to the cache memory. This means that the write-back system facilitates the speedy processing of write requests from the higher-level device.
Here, the process of writing the data from the cache memory to the storage is referred to as `write-back`. The write-back system, is one whereby data stored temporarily in the cache memory is `written back`. When there is no more space area in the cache memory, or when the space area has decreased to less than a predetermined size, the storage control device executes write-back processing. At such times, the question of which of the data present in the cache memory to select as write-back data is an important factor in determining the performance of the storage control device in a write-back system.
A typical system for selecting write-back data is the LRU (least recently used) method. In the LRU method, the data which has been present in the cache memory for the longest time without being subject to input or output is written back to the storage. This allows the more frequently accessed data to remain in the cache memory, thus making it easier to amend the cache hit rate. An example of a storage control device which uses the LRU method to select write-back data is provided by Japanese laid open patent publication A-3-172946, Unfortunately, the storage comprises a magnetic storage which has an overhead time known as the seek time and calculated in unite of milliseconds. If a long seek time is required during write-back of data selected by the LRU method, it is either impossible for any other processing to be executed during this seek time, or for data to be recorded because the write-back is still in progress, and this detracts from the performance of the magnetic storage control devise.